<template>
	<view>
		<navbar title="9.9元包邮" color="#fff" :bgColor="`url('${imgs.navbar.nine}')`"></navbar>
		<div :style="{background:`url('${imgs.navbar.nine}')`,height:'26rpx'}">
			<div v-if="list.length">
				<good :good="item" v-for="item in list" :key="item"></good>
			</div>
			<div v-else style="padding-top: 100rpx;">
				<u-empty margin-top="50rpx" mode="list"></u-empty>
			</div>
		</div>
	</view>
</template>

<script>
	import navbar from '../components/w-navbar/index.vue'
	import good from '@/components/good/index.vue'
	import imgs from '@/utils/imgs.js'
	export default {
		data() {
			return {
				imgs,
				list: [],
				page:1
			}
		},
		components: {
			navbar,
			good
		},
		methods: {
			async getList() {
				const res = await this.$api.youApi.list({
					page: this.page,
					type: 1
				})
				this.list = res.data.goods || []
			}
		},
		onLoad() {
			this.getList()
		}
	}
</script>

<style>

</style>